<?php if(!defined('HDPHP_PATH'))exit;C('SHOW_NOTICE',FALSE);?>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<title></title>
		<link rel="stylesheet" type="text/css" href="http://localhost/e-shop/xiangqu/Application/Index/View/Carts/css/cart.css"/>
		<script src="http://localhost/e-shop/xiangqu/Static/js/jquery-1.7.2.min.js" type="text/javascript" charset="utf-8"></script>
		<script type="text/javascript">
			var ajaxUpdateCart = "<?php echo U('Index/Carts/ajaxUpdateCart');?>"
			var deleteCart = "<?php echo U('Index/Carts/deleteCart');?>"
		</script>
		<script src="http://localhost/e-shop/xiangqu/Application/Index/View/Carts/js/cart.js" type="text/javascript" charset="utf-8"></script>
	</head>
	<body>
		<!--头部固定区-->
		<?php if(!defined('HDPHP_PATH'))exit;C('SHOW_NOTICE',FALSE);?>
<!--头部固定区-->
<style type="text/css">
	#header .header_content .logined a{
		font: 400 14px/50px "微软雅黑";
	}
</style>
		<div id="header_fixed"></div>
		<div id="header">
			<div class="header_content">
				<div class="logo"><img src="http://localhost/e-shop/xiangqu/Application/Index/View/Carts/images/logo.png" alt="" /></div>
				<?php if(!isset($_SESSION['username'])): ?>
				<div class="login">
					<!--<a href=""><span></span></a>-->
					<a href="<?php echo U(('Index/Register/index'));?>">注册</a>
					<a href="<?php echo U(('Index/Login/index'));?>">登录</a>
				</div>
				<?php else:  ?>
				<!--已登录begin-->
				<div class="logined">
					<a href="<?php echo U('out');?>">退出</a>
					<a href="<?php echo U('Index/Orders/myOrder');?>">我的订单</a>
					<a href="<?php echo U('Index/Carts/index');?>">购物车</a>
					<a href="<?php echo U('Index/User/index');?>"><?php echo $_SESSION['nick'] ?></a>
					<a href="<?php echo U('Index/Orders/myOrder');?>" class="face"><img src="http://localhost/e-shop/xiangqu/<?php echo $face;?>" alt="" /></a>
				</div>
				<!--已登录end-->
				<?php endif  ?>
			</div>
		</div>
		<!--头部end-->
		<!--菜单栏begin-->
		<div id="nav">
			<div class="nav_content">
				<a href="<?php echo U('Index/Index/index');?>">首页</a>
				<?php foreach ($navData as $k=>$v){?>
				<a href="<?php echo U('Index/List/index',array('cid'=>$v[cid]));?>"><?php echo $v['cname'];?></a>
				<?php }?>
				<div class="search">
					<form action="<?php echo U('Index/Search/index');?>" method="get">
						<input type="text" class="text" name="keys" placeholder="搜索" />
						<input type="submit" class="sbt" value=""/>
					</form>
				</div>
			</div>
		</div>
		<!--菜单栏end-->
		<!--菜单栏end-->
		
		<!--页面主体区域begin-->
		<div id="container">
			<form action="<?php echo U('Index/Orders/index');?>" method="post">
			<div class="cart">
				<div class="c_title">
					<span class="cart_ico"></span>
					<h2>我的购物车</h2>
				</div>
				<!--表格开始-->
				<div class="c_cont">
					<table border="0">
						<thead>
							<tr>
								<td width="200px" class='s_all'><span class="selectall select_all"></span><h3>全选</h3></td>
								<td width="200px" class="hd">商品信息</td>
								<td width="200px" class="hd">商品信息2</td>
								<td width="180px" class="hd td_numb">数量</td>
								<td width="120px" class="hd">金额(元)</td>
								<td width="60px" class="hd">操作</td>
							</tr>
						</thead>
						<tbody>
							<?php foreach ($cartData['goods'] as $k=>$v){?>
							
							<tr class="c_goods" sid="<?php echo $k;?>">
								<td><span class="select"></span><img src="http://localhost/e-shop/xiangqu/<?php echo $v['smallImg'];?>" alt="" /></td>
								<td class="g_infor1"><a href="" ><?php echo $v['name'];?></a></td>
								<td class="g_infor2">
									<?php foreach ($v['options'] as $kk=>$vv){?>
										<?php echo $kk;?>:<?php echo $vv;?>&nbsp;&nbsp;
									<?php }?>
								</td>
								<td class="t_numb">
									<a href="javascript:;" class="reduce">-</a>
									<input type="text" class="numb" value="<?php echo $v['num'];?>" style="text-align: center;" />
									<a href="javascript:;"  class="add">＋</a>
								</td>
								<td class="t_price"><sapn class="price" price=<?php echo $v['price'];?> >￥<span class="p_num"><?php echo $v['total'];?></span></sapn></td>
								<td class="t_delete"><a href="javascript:;" class="delete">删除</a></td>
							</tr>
							<?php }?>
						</tbody>
					</table>
				</div>
				<!--表格结束-->
				<!--总计部分begin-->
				<div class="total">
					<span class="t_bg"></span>
					<span class="s_all_ico select_all"></span>
					<span class="s_all_i">全选</span>
					<a href="" class="del">删除</a>
					<span class="g_sel">已选择商品<span class="g_s_n">0</span>件</span>
					<span class="total_p">合计（不计含运费）：¥<span class="s_price">0.00</span></span>
				</div>
				<!--总计部分end-->
				<!--购物车结算区块begin-->
				<div class="confirm">
					<input type="submit" class="c_sbt" value="购物车结算"/>
				</div>
				<!--购物车结算区块end-->
			</div>
			</form>
		</div>
		<!--页面主体区域end-->
		
		<!--页面底部begin-->
		<div id="footer">
			<div class="foot_wrap">
				<div class="say">
					<p class="p1">“如果你的东西和大家都一样，那干嘛还设计它？”</p>
					<p class="p2">by  Philippe Starck</p>
				</div>
				<div class="foot_logo"></div>
				<p class='infor'>Copyright 2015 版权所有 浙ICP备12027496 <a href="">热门精选</a> <a href="">热门分类</a></p>
				<p class='link'>商务合作  友情链接： 想去网  蘑菇街 360安全网址 爱图购</p>
			</div>
		</div>
		<!--页面底部end-->
	</body>
</html>
